﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="Member_Entry.ascx.cs" Inherits="cbmobile.UserControl.Member_Entry" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<%@ Register Assembly="RadCalendar.Net2" Namespace="Telerik.WebControls" TagPrefix="radCln" %>



<script type="text/javascript">
    function validateChooseDropList(oSrc, args) {
        args.IsValid = (args.Value != '0');
    }
</script>
<div class="sb-box">
    <div class="header">
        <h3>
            Thông tin thành viên
        </h3>
    </div>
    <div class=" clear">
    </div>
    <div class="bcont">
        <div class="selection">
            <asp:FormView ID="frmBlogCate" runat="server" DataSourceID="ObjectDataSource1" 
                ondatabound="frmBlogCate_DataBound" oniteminserted="frmBlogCate_ItemInserted" 
                onitemupdating="frmBlogCate_ItemUpdating">
                <EditItemTemplate>
                <table border="0">
                    <tr>
                        <td class="setup01">
                            User ID
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblUserID" runat="server" Text='<%# Bind("UserID") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Tên đăng nhập
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtTenDangNhap" runat="server" Text='<%# Bind("TenDangNhap") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Tên đầy đủ
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtTenDayDu" runat="server" Text='<%# Bind("TenDayDu") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Ngày Sinh
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtNgaySinh" runat="server" Text='<%# Bind("NgaySinh") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Giới tính
                        </td>
                        <td class="setup02">
                            <asp:CheckBox ID="ckGioiTinh" runat="server" Checked='<%# Bind("GioiTinh") %>' Enabled="true" />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Email
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtEmail" runat="server" Text='<%# Bind("Email") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Địa chỉ
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtDiaChi" runat="server" Text='<%# Bind("DiaChi") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Số điện thoại
                        </td>
                        <td class="setup02">
                            <asp:TextBox ID="txtSDT" runat="server" Text='<%# Bind("SoDienThoai") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Trạng thái
                        </td>
                        <td class="setup02">
                            <asp:DropDownList ID="ddlStatus" runat="server" >
                                </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                            <td class="C pdT10" colspan="2">
                                <asp:LinkButton ID="EditButton" runat="server" CausesValidation="False" CommandName="Update"
                                    Text="Edit" CssClass="button"><span>Update</span></asp:LinkButton>
                                &nbsp;<a href='<%=this.ListLink %>' class="button"><span>Cancel</span></a>
                            </td>
                        </tr>
                </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table border=0>
                    <tr>
                        <td class="setup01">
                            User ID
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblUserID" runat="server" Text='<%# Bind("UserID") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Tên đăng nhập
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblTenDangNhap" runat="server" Text='<%# Bind("TenDangNhap") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Tên đầy đủ
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblTenDayDu" runat="server" Text='<%# Bind("TenDayDu") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Ngày Sinh
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblNgaySinh" runat="server" Text='<%# Bind("NgaySinh") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Giới tính
                        </td>
                        <td class="setup02">
                            <asp:CheckBox ID="ckGioiTinh" runat="server" Checked='<%# Bind("GioiTinh") %>' Enabled="false" />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Email
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblEmail" runat="server" Text='<%# Bind("Email") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Mật khẩu
                        </td>
                        <td class="setup02">
                            <asp:HyperLink ID="linkDoiPass" NavigateUrl='<%# IDNavigate(Eval("UserID")) %>' runat="server">Đổi mật khẩu</asp:HyperLink>
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Địa chỉ
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblDiaChi" runat="server" Text='<%# Bind("DiaChi") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Số điện thoại
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblSDT" runat="server" Text='<%# Bind("SoDienThoai") %>' />
                        </td>
                    </tr>
                    <tr>
                        <td class="setup01">
                            Trạng thái
                        </td>
                        <td class="setup02">
                            <asp:Label ID="lblStatus" runat="server" Text='<%# StatusName(Eval("TrangThai")) %>' />
                        </td>
                    </tr>
                    <tr>
                            <td class="C pdT10" colspan="2">
                                <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                    CommandName="Edit" Text="Edit" CssClass="button"><span>Edit</span></asp:LinkButton>
                                <a href='<%=this.ListLink %>' class="button"><span>Cancel</span></a>
                            </td>
                        </tr>
                </table>
                </ItemTemplate>
            </asp:FormView>
        </div>
    </div>
</div>
<asp:ObjectDataSource ID="ObjectDataSource1" runat="server" 
    DeleteMethod="Delete" SelectMethod="Get_Member_By_ID" 
    TypeName="cbmobile.BLC.BLC_Member" UpdateMethod="Update" 
    onupdating="ObjectDataSource1_Updating">
    <DeleteParameters>
        <asp:Parameter Name="Member_ID" Type="Int32" />
    </DeleteParameters>
    <SelectParameters>
        <asp:QueryStringParameter DefaultValue="0" Name="Member_ID" 
            QueryStringField="UserID" Type="Int32" />
    </SelectParameters>
    <UpdateParameters>
        <asp:QueryStringParameter DefaultValue="0" Name="UserID" 
            QueryStringField="UserID" Type="Int32" />
        <asp:Parameter Name="TenDangNhap" Type="String" />
        <asp:Parameter Name="TenDayDu" Type="String" />
        <asp:Parameter Name="NgaySinh" Type="DateTime" />
        <asp:Parameter Name="GioiTinh" Type="Boolean" />
        <asp:Parameter Name="Email" Type="String" />
        <asp:Parameter Name="DiaChi" Type="String" />
        <asp:Parameter Name="SoDienThoai" Type="String" />
        <asp:Parameter Name="TrangThai" Type="Int32" />
    </UpdateParameters>
</asp:ObjectDataSource>
